home *** CD-ROM | disk | FTP | other *** search
/ Delphi Magazine Collection 2001 / Delphi Magazine Collection 20001 (2001).iso / DISKS / Issue35 / 35COM / About1.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  1998-05-12  |  782 b   |  44 lines

  1. unit About1;
  2.  
  3. interface
  4.  
  5. uses
  6.   Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
  7.   StdCtrls, ExtCtrls, Buttons, ComServ;
  8.  
  9. type
  10.   TXDesktopAbout = class(TForm)
  11.     CtlImage: TSpeedButton;
  12.     NameLbl: TLabel;
  13.     OkBtn: TButton;
  14.     CopyrightLbl: TLabel;
  15.     DescLbl: TLabel;
  16.     procedure FormCreate(Sender: TObject);
  17.   end;
  18.  
  19. procedure ShowXDesktopAbout;
  20.  
  21. implementation
  22.  
  23. {$R *.DFM}
  24.  
  25. procedure ShowXDesktopAbout;
  26. begin
  27.   with TXDesktopAbout.Create(nil) do
  28.     try
  29.       ShowModal;
  30.     finally
  31.       Free;
  32.     end;
  33. end;
  34.  
  35. procedure TXDesktopAbout.FormCreate(Sender: TObject);
  36. var
  37.     Buff: array [0..255] of Char;
  38. begin
  39.     GetModuleFileName (hInstance, Buff, sizeof (Buff));
  40.     DescLbl.Caption := Buff;
  41. end;
  42.  
  43. end.
  44.